<%@ page import="org.dizem.groupon.Constants" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
	<link rel="stylesheet" href="/css/jquery-ui-1.8.14.custom.css" type="text/css" media="screen"
		  charset="utf-8"/>
	<script type="text/javascript" src="../js/jquery-1.6.js"></script>
	<script type="text/javascript" src="../js/jquery-ui-1.8.14.custom.min.js"></script>
	<script type="text/javascript" src="../js/common.js"></script>
	<script type="text/javascript" src="../js/login.js"></script>
	<link rel="stylesheet" href="../css/index.css" type="text/css" media="screen" charset="utf-8"/>
	<meta http-equiv=content-type
		  content="text/html; charset=UTF-8;charset=utf-8"/>

	<script type="text/javascript">
		var userType = '<%= session.getAttribute(Constants.SESSION_USER_TYPE) %>';
		if(userType != "ADMIN") {
			window.location.href="/page/login.jsp";
		}
	</script>
</head>
<body>
<div id="hdw">
	<div id="hd">
		<div id="logo">
			<a href="/page/index.jsp" class="link"
			   target="_blank"><img src="../image/logo.png"/></a>
		</div>
		<div class="guides">
			<div class="city">
				<h2>管理后台</h2>
			</div>
			<div id="guides-city-change" class="change"></div>
		</div>
		<ul class="nav cf">
			<li id="main_li">
				<a href="/admin/">首页</a>
			</li>
			<li id="item_li">
				<a href="/admin/listCurrentItem.action">团购</a>
			</li>
			<li id="order_li">
				<a href="/admin/listWaitingOrder.action">订单</a>
			</li>
			<li id="user_li">
				<a href="/admin/listUser.action">用户</a>
			</li>
			<li id="merchant_li">
				<a href="/admin/listMerchant.action">商户</a>
			</li>
			<li id="other_li">
				<a href="/admin/listCategory.action">其他</a>
			</li>
		</ul>


		<div class="logins">
			<ul id="account">
				<c:choose>
					<c:when test="${SESSION_USERNAME == null}">
						<li class="login">
							<a href="#" id="btn_register">注册</a>
						</li>
						<li class="login">
							<a href="#" id="btn_login">登录</a>
						</li>
					</c:when>
					<c:otherwise>
						<li class="account">
							<a href="#">${SESSION_USERNAME}</a>
						</li>
						<li class="logout">
							<a href="/logout">退出</a>
						</li>
					</c:otherwise>
				</c:choose>
			</ul>
		</div>
	</div>
</div>
</body>
</html>